package com.lp.common.context;

/**
 * @program: backend
 * @description:
 * @author: Ke.Song
 * @since: 2024-03-11 21:13:37
 */
public class ContextHolder {
    static {
        STRATEGY = new ThreadLocalContextHolderStrategy();
    }

    private static final ThreadLocalContextHolderStrategy STRATEGY;

    /**
     * Clear context.
     */
    public static void clearContext() {
        STRATEGY.clearContext();
    }

    /**
     * Gets context.
     *
     * @return the context
     */
    public static CurrentUserInfo getContext() {
        return STRATEGY.getContext();
    }
}
